﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="AddUpdateRule.aspx.cs" Inherits="Manageweb_FanLi_AddUpdateRule" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <style type="text/css" >
       #addrule td { padding-top:8px;}
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <fieldset>
            <legend>
                <label runat="server" id="lblTitle">
                    添加新规则</label></legend>
            <div id="addrule" style="width:100%">
                <table  style="margin:0;padding:0; width:500px;" cellpadding="0" cellspacing="0">
                    <tr>
                        <td  style="width:80px; ">
                            金额下限:
                        </td>
                        <td style="width:90px;">
                            <asp:TextBox ID="txtXX" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                                ErrorMessage="*" ControlToValidate="txtXX" Display="Dynamic" 
                                SetFocusOnError="True"></asp:RequiredFieldValidator>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" 
                                ControlToValidate="txtXX" Display="Dynamic" ErrorMessage="正数" 
                                SetFocusOnError="True" ValidationExpression="^[+]?([1-9][0-9]*|0)(\.[0-9]+)?$"></asp:RegularExpressionValidator> &nbsp;
                        </td>
                    </tr>
                    <tr>
                        <td style="width:80px;">
                            金额上限:
                        </td>
                        <td>
                            <asp:TextBox ID="txtSX" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                                ControlToValidate="txtSX" Display="Dynamic" ErrorMessage="*" 
                                SetFocusOnError="True"></asp:RequiredFieldValidator>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="server" 
                                ControlToValidate="txtSX" Display="Dynamic" ErrorMessage="正数" 
                                ValidationExpression="^[+]?([1-9][0-9]*|0)(\.[0-9]+)?$"></asp:RegularExpressionValidator>
                            <asp:CompareValidator ID="CompareValidator1" runat="server" 
                                ControlToCompare="txtXX" ControlToValidate="txtSX" Display="Dynamic" 
                                ErrorMessage="上限要大于下线" Operator="GreaterThan" SetFocusOnError="True" 
                                Type="Double"></asp:CompareValidator>
                        </td>
                    </tr>
                    <tr>
                        <td style="width:80px;">
                            等级:</td>
                        <td>
                            <asp:TextBox ID="txtDescription" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
                                ControlToValidate="txtDescription" Display="Dynamic" ErrorMessage="*" 
                                SetFocusOnError="True"></asp:RequiredFieldValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px;">
                            推荐人1:
                        </td>
                        <td>
                            <asp:TextBox ID="txtTJR1" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" 
                                ControlToValidate="txtTJR1" Display="Dynamic" ErrorMessage="正小数或零" 
                                SetFocusOnError="True" 
                                ValidationExpression="^[1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px;">
                            推荐人2:
                        </td>
                        <td>
                            <asp:TextBox ID="txtTJR2" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator4" runat="server" 
                                ControlToValidate="txtTJR2" Display="Dynamic" ErrorMessage="正小数或零" 
                                SetFocusOnError="True" 
                                ValidationExpression="^[1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px;">
                            推荐人3:
                        </td>
                        <td>
                            <asp:TextBox ID="txtTJR3" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator5" runat="server" 
                                ControlToValidate="txtTJR3" Display="Dynamic" ErrorMessage="正小数或零" 
                                SetFocusOnError="True" 
                                ValidationExpression="^[1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px;">
                            推荐人4:
                        </td>
                        <td>
                            <asp:TextBox ID="txtTJR4" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator6" runat="server" 
                                ControlToValidate="txtTJR4" Display="Dynamic" ErrorMessage="正小数或零" 
                                SetFocusOnError="True" 
                                ValidationExpression="^[1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px;">
                            推荐人5:
                        </td>
                        <td>
                            <asp:TextBox ID="txtTJR5" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator7" runat="server" 
                                ControlToValidate="txtTJR5" Display="Dynamic" ErrorMessage="正小数或零" 
                                SetFocusOnError="True" 
                                ValidationExpression="^[1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px;">
                            推荐人6:
                        </td>
                        <td>
                            <asp:TextBox ID="txtTJR6" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator8" runat="server" 
                                ControlToValidate="txtTJR6" Display="Dynamic" ErrorMessage="正小数或零" 
                                SetFocusOnError="True" 
                                ValidationExpression="^[1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px;">
                            推荐人7:
                        </td>
                        <td>
                            <asp:TextBox ID="txtTJR7" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator9" runat="server" 
                                ControlToValidate="txtTJR7" Display="Dynamic" ErrorMessage="正小数或零" 
                                SetFocusOnError="True" 
                                ValidationExpression="^[1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px;">
                            推荐人8:
                        </td>
                        <td>
                            <asp:TextBox ID="txtTJR8" runat="server" Width="90px"></asp:TextBox>
                        </td>
                        <td>
                        <asp:RegularExpressionValidator ID="RegularExpressionValidator10" runat="server" 
                                ControlToValidate="txtTJR8" Display="Dynamic" ErrorMessage="正小数或零" 
                                SetFocusOnError="True" 
                                ValidationExpression="^[1-9]\d*\.\d*|0\.\d*[1-9]\d*|0?\.0+|0$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td  style="width:80px; ">
                            &nbsp;</td>
                        <td>
                            &nbsp;<asp:Button ID="btnAdd" runat="server" Text="添加" onclick="btnAdd_Click" />
                            <asp:Button ID="btnUpdate" runat="server" onclick="btnUpdate_Click" Text="修改" 
                                Visible="False" />
                        </td>
                        <td>
                            <input id="Reset1" type="reset" value="重置" /></td>
                    </tr>
                     
                </table>
                <div style="color:Red; padding-top:10px">
                          说明: 在推荐人文本框中输入小数或零</div>
            </div>
        </fieldset>
        
    </div>
    
    
                 
    </form>
</body>
</html>
